<?php

/**
 * Contains a function to print an error message.
 *
 * PHP Version 5
 *
 * @category BuyLocal
 * @package  BuyLocal
 * @author   Kevin Fodness <kevin.fodness@gmail.com>
 * @author   Mike Pennisi <mpennisi@andrew.cmu.edu>
 * @author   Aaron Ryden <aryden@gmail.com>
 * @license  http://opensource.org/licenses/gpl-license.php GNU Public License
 * @link     http://code.google.com/p/buylocalopensourcerensselaer/
 */

/**
 * A function to print an error message.
 *
 * @param string $message The error text to display to the end user.
 * @param int    $indent  The number of spaces to indent the HTML.
 *
 * @access public
 * @return null
 */
function printError($message, $indent = 0)
{
    $spacing = str_pad('', $indent, ' ', STR_PAD_LEFT);
    echo $spacing, '<p class="alert">', $message, '</p>', "\n";
}

?>